template_format: semantic-kernel
template: |
    [INSTRUCTION]
    Work with user to determine if he or she would like to execute the current step for the first time.

    [THOUGHT PROCESS]
    [Goal]
    The goal of proposed step.
    [THOUGHT]
    To solve this problem, I should carefully analyze the question and response to identify if user is willing to begin the current action. 
    Any facts I discover earlier in my thought process should be repeated here to keep them readily available.
    [QUESTION]
    If there is any ambiguity in the chat history, ask the follow up question to the user to get clarification on whether the user wants to repeat the previous step.
    The way you will check if the user wants to execute the step is by asking the question "{{$message}}". 
    IMPORTANT: Do NOT update the wording in the question stated above. If you need clarification, you will ask that question word for word.
    If the user says something along the lines of "yes", "sure", "fine", "ok", then they are asking to start the step.
    [RESPONSE]
    The result of the action will be provided here. It could be result or error message of the action, or chat history between assistant and user to tackle the problem.
    ... (These THOUGHT/QUESTION/RESPONSE can repeat until the final answer is reached.)
    [FINAL ANSWER]
    Once I have gathered all the necessary observations and can reliably tell if user would like to repeat the step for one more time, output TRUE or FALSE.
    [END THOUGHT PROCESS]

    Example:
    [Goal]
    {{$goal}}
    [QUESTION]
    {{$message}}
    [RESPONSE]
    yes
    [THOUGHT]
    Based on the response, the user wants to execute the current step.
    [FINAL ANSWER]
    TRUE

    IMPORTANT REMINDER: your each response should contain at most one question. Do not provide more than one step.  
    Let's break down the problem step by step and think about the best approach.

    Begin!

    [Goal]
    {{$goal}}
    {{$agentScratchPad}}
    [THOUGHT]    
description: Given the chat history, determine if user would like to execute the previous task for one more time. If not concluded, generate the next message for follow up.
name: CheckRepeatStep
input_variables:
  - name:          goal
    description:   The goal of proposed step
  - name:          message
    description:   he message to display to the user
  - name:          agentScratchPad
    description:   The agent's scratch pad
execution_settings:
  text-davinci-003:
    temperature:       0.0
    top_p:             1.0
    presence_penalty:  0.0
    frequency_penalty: 0.0
    max_tokens:        400
    stop_sequences:    ["[RESPONSE]"]
  default:
    temperature:       0.0
    top_p:             1.0
    presence_penalty:  0.0
    frequency_penalty: 0.0
    max_tokens:        400
    stop_sequences:    ["[RESPONSE]"]
